//
//  PrivateMessages.h
//  百车易车险
//
//  Created bychenxu on 14-8-29.
//  Copyright (c) 2014年 chenxu. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "PrivateMessage.h"
@interface PrivateMessages : NSObject<NSCoding,NSCopying>

@property (readwrite, nonatomic, strong) NSNumber *page, *pageSize, *totalPage, *totalRow;
@property (assign, nonatomic) BOOL canLoadMore, willLoadMore, isLoading;
@property (readwrite, nonatomic, strong) NSDictionary *propertyArrayMap;
//list为已发送队列，nextMessages为待发送队列
@property (readwrite, nonatomic, strong) NSMutableArray *list, *nextMessages;


@property (readwrite, nonatomic, strong) NSString *orderid;
@property (readwrite, nonatomic, strong) NSString *nextContent;

+ (PrivateMessages *)priMsgsWithOrder:(NSString *)orderid;

- (NSString *)localPrivateMessagesPath;
- (NSDictionary *)toParams;
- (void)configWithObj:(PrivateMessages *)priMsgs;

- (void)sendNewMessage:(PrivateMessage *)nextMsg;
- (void)receiveNewMessage:(PrivateMessage *)Msg;
- (void)sendSuccessMessage:(PrivateMessage *)sucessMsg andOldMessage:(PrivateMessage *)oldMsg;
- (void)deleteMessage:(PrivateMessage *)msg;


@end
